package com.oocl.euc.core.builder;

import com.oocl.euc.core.attachment.model.Attachment;
import com.oocl.euc.core.requestform.model.RequestAttachment;
import org.springframework.stereotype.Component;

@Component
public class RequestAttachmentBuilder {

    private RequestAttachment requestAttachment;

    public RequestAttachmentBuilder defaultBuilder() {

        requestAttachment = new RequestAttachment();
        requestAttachment.setDescription("Request Attachment Desc");
        return this;
    }

    public RequestAttachmentBuilder withAttachment(Attachment attachment){

        this.requestAttachment.setAttachment(attachment);
        return this;
    }

    public RequestAttachment create(){
        return this.requestAttachment;
    }

}
